]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
theme: Hide panel underline under the do not disturb icon
authorJonas Dreßler <verdre@v0yd.nl>
Thu, 20 Feb 2020 19:10:54 +0000 (20:10 +0100)
committerFlorian Müllner <fmuellner@gnome.org>
Tue, 25 Feb 2020 15:47:17 +0000 (16:47 +0100)
Hide the focused/active indicator of the panel underneath the
do-not-disturb icon.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1037

data/theme/gnome-shell-sass/widgets/_calendar.scss
data/theme/gnome-shell-sass/widgets/_panel.scss
js/ui/dateMenu.js

index 207a30267d7ac2a55c686270f8dd9363eeab26f6..8074b2106b28d2c106eb5123638acb6b3921830e 100644 (file)
@@ -1,6 +1,13 @@
 /* Date/Time Menu */
 
-.clock-display-box { spacing: $base_spacing; }
+.clock-display-box {
+  spacing: $base_spacing / 2;
+
+  .clock {
+    padding-left: $base_padding;
+    padding-right: $base_padding;
+  }
+}
 
 // overall menu
 #calendarArea {
index 222d68629ba66f6dc09ac35948b86c24b9afdcda..56c445a74382d6b6580b4bdf4de682f7a5a42ce8 100644 (file)
@@ -54,9 +54,6 @@ $panel_height: 1.86em;
     }
 
     &:active, &:overview, &:focus, &:checked {
-      // Trick due to St limitations. It needs a background to draw a box-shadow
-      background-color: rgba(0, 0, 0, 0.01);
-      box-shadow: inset 0 -2px 0 0 lighten($selected_bg_color,5%);
       color: lighten($panel_fg_color, 20%);
     }
 
@@ -82,6 +79,26 @@ $panel_height: 1.86em;
     }
   }
 
+  .panel-button {
+    &:active, &:overview, &:focus, &:checked {
+      // Trick due to St limitations. It needs a background to draw a box-shadow
+      background-color: rgba(0, 0, 0, 0.01);
+      box-shadow: inset 0 -2px 0 0 lighten($selected_bg_color,5%);
+    }
+  }
+
+  .panel-button.clock-display {
+    // Move highlight from .panel-button to .clock
+    &:active, &:overview, &:focus, &:checked {
+      box-shadow: none;
+
+      .clock {
+        background-color: rgba(0, 0, 0, 0.01);
+        box-shadow: inset 0 -2px 0 0 lighten($selected_bg_color,5%);
+      }
+    }
+  }
+
   .panel-status-indicators-box,
   .panel-status-menu-box {
     spacing: 2px;
index fbfccfc1b40d5d08518349d86c783b2acba9d161..a517df43467aa0bd16a1b3f049d27cdfaee1b1fb 100644 (file)
@@ -553,7 +553,9 @@ class DateMenuButton extends PanelMenu.Button {
             menuAlignment = 1.0 - menuAlignment;
         super._init(menuAlignment);
 
-        this._clockDisplay = new St.Label({ y_align: Clutter.ActorAlign.CENTER });
+        this._clockDisplay = new St.Label({ style_class: 'clock' });
+        this._clockDisplay.clutter_text.y_align = Clutter.ActorAlign.CENTER;
+
         this._indicator = new MessagesIndicator();
 
         const indicatorPad = new St.Widget();